import {createRouter, createWebHistory} from 'vue-router'
import {useUserStore} from "@/stores/user"
import {ElMessage} from "element-plus";

const modules = import.meta.glob('../views/system/*/*.vue')

const router = createRouter({
    history: createWebHistory(import.meta.env.BASE_URL),
    routes: [
        {
            path: '/home',
            name: 'home',
            component: () => import('../views/Home.vue')
        },
        {
            path: '/:pathMatch(.*)*',
            name: '404',
            component: () => import('../views/404.vue')
        },
    ]
})

export default router
